#ifndef _CAR_ADT_H_
#define _CAR_ADT_H_

#include "cityADT.h"
#include "drawerADT.h"


#define BASE_SPEED 500000.0
#define BASE_SPEED_MULTIPLIER 2
#define MAX_SPEED 0.025
#define MIN_SPEED 0.05 
typedef struct carCDT* carADT;

enum CAR_DIRECTION {CAR_N, CAR_S, CAR_E, CAR_W};
enum CAR_SPEED {CAR_SLOW, CAR_NORMAL, CAR_FAST, CAR_CRAZY, NUM_CAR_SPEEDS};

//Firs parameter is of type SPEED. Parameter 'direction' is of type CAR_DIRECTION
carADT newCar(int speed, int initPosX, int initPosY, cityADT city, int direction, int rSeed, int uniqueId, drawerADT drawer);

//Parameter 'direction' is of type CAR_DIRECTION
void setPos(carADT car, int posX, int posY, int direction);

int multiplySpeed(carADT car, double multiplier);
void resetSpeeds(carADT car);

int getCarY(carADT car);
int getCarX(carADT car);
int getCarId(carADT car);

void freeCar(carADT car);

#endif
